package cn.tx.service.Impl;

import cn.tx.dao.ScourseDao;
import cn.tx.model.Scourse;
import cn.tx.service.ScourseService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class ScourseServiceImpl implements ScourseService {
    @Autowired
    private ScourseDao scourseDao;
    @Override
    public int addScourse (Scourse scourse){
        return scourseDao.addScourse(scourse);
    }
    @Override
    public Scourse findByName(String name){
       return scourseDao.findByName(name);
    }
    @Override
    public List<Scourse> findList(Map<String, Object> querymap){
       return scourseDao.findList(querymap);
    }
    @Override
    public List<Scourse> findAll(){
       return scourseDao.findAll();
    }
    @Override
    public int findTotal(Map<String, Object> querymap){
        return scourseDao.findTotal(querymap);
    }
    @Override
    public int UpdateScourseById(Scourse scourse){
        return scourseDao.UpdateScourseById(scourse);
    }
    @Override
    public int delete(String ids){
       return scourseDao.delete(ids);
    }
}
